Computer graphics systems are commonly used for displaying graphical objects on a display screen. These graphical objects include points, lines, polygons, and three dimensional solid objects. Using techniques well known in the art, color and surface details can be added to areas and surfaces of objects. One particularly useful technique for adding surface detail to areas or surfaces is texture mapping. Using texture mapping, a pattern image or texture map is combined with an area or surface of an object thereby producing a modified object with the added detail of the texture map. For example, given a flat black solid cube and a texture map defining a wood grain pattern, the texture mapping technique can be used to map the wood grain pattern onto the cube thereby producing a cube that appears to be made of wood. The texture mapping technique is particularly useful as surface detail becomes finer and more intricate thereby rendering the use of geometric primitives less practical.
The effect of texture mapping onto objects can be further improved using filters. Filters are useful for blurring or uniformly reducing the detail of a texture mapped onto an object. Filtering used in this way is particularly useful for modeling the distance that an object is located from the viewer, the effects of atmospheric fog, or the effect of poor lighting. For example, one would expect that an object positioned close to the viewer would appear to have greater detail that an object located some distance away from the viewer. This effect can be created in a computer graphics environment by applying a filter to the more distant object. One limitation in the use of filters in the prior art is the fact that filters typically must be applied uniformly for each of the pixels in an area or surface of an object. This limitation on the use of filters is particularly troublesome for generating and displaying objects where more than one filter level is necessary. For example, a polygon may be generated depicting a road extending into the distance. As expected for a perspective view, the sides of the road would be positioned wide apart in the foreground and converging to a point in the distance. Texture mapping may be used to apply an asphalt surface to the road object. A viewer would expect, however, to see finer detail of the road texture in the foreground versus the road texture in the distance. In order to appropriately model this perspective view, a fine detail filter should be used in the foreground of the road object, and a coarse detail filter should be used in the more distant region of the road object. Further realism may be achieved by using a plurality of filters at intermediate points of the road object from the nearest point to the furthest point. Typically, however, prior art systems have been unable to apply more than one filter to a single area or surface.
One way used in the prior art for applying variations in the detail of a texture mapped onto an object is to apply a filter to each pixel of an area or surface of the object. In this way, complete control over the rendering of an object can be achieved. Unfortunately, however, the use of a separate filtering computation for each pixel is very computationally expensive. Use of the pixel filtering technique requires extremely fast and typically expensive hardware. In some situations for large and complex objects, the use of the pixel filtering technique may not be possible for generating the object within the allowable time constraints. Thus, a better technique is needed for applying variant filter levels to a graphical object.
It is therefore an object of the present invention to provide a technique for applying various filter levels to areas and surfaces of a single object. If is further an object of the present invention to provide a means for applying various filter levels to areas and surfaces of an object without requiring an expensive filter computation on a per pixel basis. It is a further object of the present invention to provide a means and method for applying atmospheric and texture parameter variations to an object based on its distance from the eye of a viewer.